Skip to content

fix: resolve failing tests and implement missing functionality - #457

Open
stooit wants to merge 1 commit into
mainfrom
quantcode/e2e-tier1-921-1794240856
Open

stooit wants to merge 1 commit into
mainfrom
quantcode/e2e-tier1-921-1794240856

Conversation

@stooit

@stooit stooit commented Nov 9, 2026

Copy link
Copy Markdown
Contributor

Summary

  • calculator.divide: throws Division by zero when b === 0
  • string-utils: implemented truncate (word-boundary, ellipsis counts toward maxLength, safe for maxLength < 3); wordCount splits on /\s+/
  • task-manager: implemented remove (returns boolean), update (partial update, false for unknown id), sortBy (priority/status/createdAt)
  • date-utils.formatRelative: days rounded symmetrically via Math.round(Math.abs(hours)/24) (fixes off-by-one)
  • validator: isEmail accepts long TLDs; isUrl accepts URLs with ports; stale BUG comments removed

Verification

  • bun test: 60 pass / 0 fail (was 44/16)
  • bunx tsc --noEmit: clean
  • Reviewed twice (initial + follow-up re-review), no critical/high issues

Assumptions

  • No test files modified, no dependencies added.
  • truncate with maxLength < 3 returns a truncated ellipsis (not covered by tests; chosen to honour the max-length contract).
  • sortBy("createdAt") sorts oldest first; update ignores undefined fields.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant